Skip to content

Domoticz

322 Topics 2.3k Posts
  • MDRemote not working in Stable Release 3.8153

    2
    0 Votes
    2 Posts
    888 Views
    D
    On version 4.9700 Still, does not work. PKG_HASH:=2772d9f64cc552d02a8c44f5e076b58f13b39d69 IRSensor1 IRSensor2
  • New Gateway not showing on Domoticz

    7
    0 Votes
    7 Posts
    2k Views
    Andrew MaynardA
    Once again thanks for your help! of course it works now lol. i soldered it back together and it works perfectly!
  • Domoticz version 4.9700 released (stable)

    9
    3 Votes
    9 Posts
    3k Views
    MasMatM
    @nagelc I've been afraid to try that. Maybe do a full backup and try it. Not sure if I should erase everything first or not.
  • This topic is deleted!

    1
    0 Votes
    1 Posts
    61 Views
    No one has replied
  • Energy meter with two tariffs

    6
    0 Votes
    6 Posts
    2k Views
    D
    Thanks. I use a MQTT gateway between the node and the domoticz. It seems that I have no choice than create two childs, one for each tariff.
  • MySensors suddenly stop working [solved]

    8
    0 Votes
    8 Posts
    2k Views
    F
    SOLVED please see first post
  • Hank HKZW-DWS01 Window Sensor problem

    2
    0 Votes
    2 Posts
    993 Views
    J
    Hello All, I have corrected the problem with these sensors. I found a .hml configuration file on the OpenZwave website for these devices. I copied this file into the directory /home/pi/domoticz/Config/hank and then renamed it to the original file Domoticz had for these devices after backing up the originals. I then tried to exclude these two devices, but I could not. Domoticz added them back with new device ID's and the devices were able to their state changes as expected.
  • Sending data to Domoticz issue

    5
    0 Votes
    5 Posts
    1k Views
    gohanG
    Comment the my_debug and try again
  • Setting up ethernet gateway

    2
    0 Votes
    2 Posts
    736 Views
    thomas2000T
    Rain gauge with scetch https://www.mysensors.org/build/rain Edit: is it even possible to let the sketch work on an uno?
  • relay as a switch not as a button (domoticz)

    25
    0 Votes
    25 Posts
    6k Views
    zrom69Z
    thanks for the work you did i add the motion sensor and light level sensor its not working well you can help me thank you /* Relay with toggle switch sketch modified to work with no uplink to gateway Toggle switch connected between pin3 and ground. */ #define MY_DEBUG // Enable debug prints to serial monitor #define MY_RADIO_NRF24 // Enable and select radio type attached #define MY_TRANSPORT_WAIT_READY_MS 5000 //set how long to wait for transport ready in milliseconds #include <MySensors.h> #include <Bounce2.h> #define CHILD_ID_LEVEL A0 #define RELAY_PIN 5 // Arduino Digital I/O pin number for relay #define SWITCH_PIN 4 // Arduino Digital I/O pin number for switch #define DIGITAL_INPUT_SENSOR 3 // The digital input you attached your motion sensor. (Only 2 and 3 generates interrupt!) #define CHILD_ID 1 // Id of the sensor child #define CHILD_ID_MOT 2 //motion sensor #define CHILD_ID_LEVEL 3 #define RELAY_ON 1 #define RELAY_OFF 0 Bounce debouncer = Bounce(); int oldswitchState = 0; bool state = false; bool firstStart = true; int photocellPin = 0; // The photoresistor and resistance 10 / 12KOhms connected on the pin / analog pin A0 int photocellReading; unsigned long interval= 6000;//dht.getMinimumSamplingPeriod(); // the time we need to wait unsigned long previousMillis=0; // millis() returns an unsigned long. unsigned long SLEEP_TIME = 120000; // Sleep time between reports (in milliseconds) MyMessage msg(CHILD_ID, V_STATUS); MyMessage msgMot(CHILD_ID_MOT, V_TRIPPED); MyMessage msgLight(CHILD_ID_LEVEL, V_LIGHT_LEVEL); void setup(){ pinMode(SWITCH_PIN, INPUT_PULLUP); // Setup the button pin, Activate internal pull-up debouncer.attach(SWITCH_PIN); // After setting up the button, setup debouncer debouncer.interval(5); pinMode(RELAY_PIN, OUTPUT); // set relay pin in output mode digitalWrite(RELAY_PIN, RELAY_OFF); // Make sure relay is off when starting up } void presentation() { // Send the sketch version information to the gateway and Controller sendSketchInfo("Relay & Toggle", "1.0"); // Register all sensors to gw (they will be created as child devices) present(CHILD_ID, S_BINARY); present(CHILD_ID_LEVEL, S_LIGHT_LEVEL); present(CHILD_ID_MOT, V_TRIPPED); //me } void loop(){ if (firstStart) { // this code is only run once at startup debouncer.update(); oldswitchState = debouncer.read(); // set oldswitchState to the current toggle switch state send(msg.set(false), false); // notify controller of current state no ack firstStart = false; // set firstStart flag false to prevent code from running again } debouncer.update(); int switchState = debouncer.read(); // Get the update value if (switchState != oldswitchState) { // check for new throw of toggle switch state = !state; // Toggle the state digitalWrite(RELAY_PIN, state ? RELAY_ON : RELAY_OFF); // switch the relay to the new state send(msg.set(state), false); // notify controller of current state no ack oldswitchState = switchState; } // Read digital motion value boolean tripped = digitalRead(DIGITAL_INPUT_SENSOR) == HIGH; // only run loop if time has passed. unsigned long currentMillis = millis(); // grab current time // check if "interval" time has passed if ((unsigned long)(currentMillis - previousMillis) >= interval) { send(msgMot.set(tripped?"1":"0")); photocellReading = analogRead(photocellPin)/10; // Conversion en 100% (approximatif) // Valeur de la photorésistance avec lampe torche devant = ~1000 Serial.print("Luminosité : "); Serial.println(photocellReading); send(msgLight.set(photocellReading, 1)); if(tripped == 1 && photocellReading < 30) // Si la luminosité est inférieure à 30% #ifdef MY_DEBUG Serial.print("Motion: "); Serial.println(tripped); #endif } } /-------------------start of functions--------------------------/ void receive(const MyMessage &message) { if (message.type == V_STATUS) { // check to see if incoming message is for a switch state = message.getBool(); // get the new state digitalWrite(RELAY_PIN, state ? RELAY_ON : RELAY_OFF); // switch relay to new state /*---- Write some debug info----*/ Serial.print("Incoming change for sensor:"); Serial.print(message.sensor); Serial.print(", New status: "); Serial.println(message.getBool()); } }
  • This topic is deleted!

    1
    0 Votes
    1 Posts
    91 Views
    No one has replied
  • another sensors connection via usb ?

    8
    1
    0 Votes
    8 Posts
    2k Views
    K
    @rejoe2 Two different usb-serial converters work well without additional settings. And You're right - in any case it makes sense to use different ChildIDs :)
  • I can not add sensors

    2
    0 Votes
    2 Posts
    1k Views
    K
    It seems all OK. Simply click on green arrow to put sensors on Temperature tab and etc.
  • Domotiocz + Rain gauge

    61
    0 Votes
    61 Posts
    31k Views
    J
    Ok thanks for the reply.... I was only wanting to use your sketch as my node is battery powered and the mysensors example uses a lot of power as it doesn't sleep. I will try and modify it.
  • Domoticz V_TEXT sensor now bidirectional

    7
    7 Votes
    7 Posts
    2k Views
    edsteveE
    Thanks. Found it.
  • Water volume widget

    5
    0 Votes
    5 Posts
    1k Views
    gohanG
    You may need to look at influxdb and grafana to do the reports you are looking for
  • Presenting and controlling variables in domoticz

    4
    0 Votes
    4 Posts
    1k Views
    I
    @pjr said in Presenting and controlling variables in domoticz: Cannot get the point what you exactly mean but I think you should check for what child the message is for: if(message.sensor == CHILD_ID_aeg2** && message.type == ...) { ..do suff.. } Thank you, message.sensor was the thing i needed. Browsed cpp and h files in mysensors library and googled, but couldn't find variables to use with message.*. :smiley:
  • distance in km

    2
    0 Votes
    2 Posts
    1k Views
    alexsh1A
    Anyone please? send(Prefix.set("km")); does not work
  • Time not received after requestTime

    1
    0 Votes
    1 Posts
    931 Views
    No one has replied
  • Domoticz with DIY "razberry" card

    1
    4
    3 Votes
    1 Posts
    951 Views
    No one has replied

16

Online

11.7k

Users

11.2k

Topics

113.1k

Posts